import request from '@/utils/request'
// 列表
export function changeList(data) {
  return request({
    url: `/stability-box-change/list`,
    method: 'post',
    data
  })
}
// 详情
export function changeDetail(id) {
  return request({
    url: `/stability-box-change/detail?id=${id}`,
    method: 'get'
  })
}
// 状态下拉
export function statusSelect() {
  return request({
    url: `/stability-box-change/all/state`,
    method: 'get'
  })
}
// 所有申请人
export function applyPepole() {
  return request({
    url: `/stability-box-change/all/creator`,
    method: 'get'
  })
}
// 旧稳定性箱
export function oldList() {
  return request({
    url: `/stability-box-change/all/plan-doing/instrument`,
    method: 'get'
  })
}
// 获取计划
export function getPlan(id) {
  return request({
    url: `/stability-box-change/select/plan?id=${id}`,
    method: 'get'
  })
}
// 创建
export function changeCreate(data) {
  return request({
    url: `/stability-box-change/create`,
    method: 'post',
    data
  })
}
// 确认
export function qUpdate(data) {
  return request({
    url: `/stability-box-change/check`,
    method: 'post',
    data
  })
}
// 操作历史
export function history(id) {
  return request({
    url: `/stability-box-change/history/list?id=${id}`,
    method: 'get'
  })
}
// 审批跳转
export function Sdetail(id) {
  return request({
    url: `/stability-box-change/flow-id/detail?id=${id}`,
    method: 'get'
  })
}
// 撤销
export function undoX(data) {
  return request({
    url: `/check/cancel`,
    method: 'post',
    data
  })
}
